﻿<UserControl x:Class="TM.QWeibo.Client.UserControls.UserAvatar"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d"
    FontFamily="{StaticResource PhoneFontFamilyNormal}"
    FontSize="{StaticResource PhoneFontSizeNormal}"
    Foreground="{StaticResource PhoneForegroundBrush}"
    d:DesignHeight="480" d:DesignWidth="480">
    
    <Grid x:Name="LayoutRoot" Background="Transparent" Height="80" Tap="LayoutRoot_Tap">
        <StackPanel x:Name="spUserInfo" Orientation="Horizontal" Grid.Row="0">
            <Image x:Name="imgAvator" Source="{Binding Head, Converter={StaticResource HeadUrlConverter},ConverterParameter='100'}" Stretch="Fill" Width="80" Height="80" Margin="12,0,12,0"/>
            <StackPanel HorizontalAlignment="Center" VerticalAlignment="Center">
                <StackPanel Orientation="Horizontal">
                    <TextBlock x:Name="tbUserNickName" Text="{Binding NickName}" Style="{StaticResource UserAvatarNickName}"/>
                    <Image Source="/Resource/Icons/v.png" Stretch="Fill" Width="24" Height="24" Visibility="{Binding IsVip, Converter={StaticResource IntToVisibleConverter}}"/>
                </StackPanel>
                <TextBlock x:Name="tbUserName" Text="{Binding Name}" Style="{StaticResource UserAvatarName}"/>
            </StackPanel>
        </StackPanel>
    </Grid>
</UserControl>
